package com.ewzj.bigdata.mvp.contract

import com.ewzj.bigdata.mvp.model.reqbean.Reqpagebean
import com.ewzj.bigdata.mvp.model.rspbean.*
import com.ewzj.bigdata.mvp.ui.adapter.HomePageAdapter
import com.ewzj.bigdata.mvp.ui.adapter.HourseTypeAdapter
import com.jess.arms.mvp.IModel
import com.jess.arms.mvp.IView
import io.reactivex.Observable

/**
 * author:zhangjing
 * 作用:
 * return:
 */
class HomeFragmentContract{
    interface View : IView{
        fun initTypeRecylerveiew(adapter: HourseTypeAdapter)
        fun initHomeRecylerveiew(adapter: HomePageAdapter)
        fun initHomeNumber(rspdata: RspHomeData)
        fun locationCity(city: String,islocation: Boolean)
        fun initbanner(bannerdata:AdBean)
        fun showPopAdview(adBean: AdBean)
        fun setTopicEnter(data:BaseListData<TopicEnterBean>,isvisiable:Boolean)
    }

    interface Model: IModel {
        fun getHomev3(page: Reqpagebean): Observable<RspHomeData>
        fun <T> subList(list: List<T>?): List<List<T>>
        fun getAdList(): Observable<BaseData<AdBean>>
        fun gerRecHomelist(page: Reqpagebean):Observable<RspHomeData>
        fun gerNewHomelist(page: Reqpagebean):Observable<RspHomeData>
        fun gerOldHomelist(page: Reqpagebean):Observable<RspHomeData>
        fun gerRentHomelist(page: Reqpagebean):Observable<RspHomeData>
        fun getpopAd(): Observable<BaseData<AdBean>>
        fun gettopicEnter():Observable<BaseData<BaseListData<TopicEnterBean>>>
    }
}